package cn.xclink.kernel.mapper;

import java.util.List;

import org.apache.ibatis.annotations.InsertProvider;
import org.apache.ibatis.annotations.Options;

import tk.mybatis.mapper.provider.SpecialProvider;
import cn.xclink.common.mapper.BaseMapper;
import cn.xclink.kernel.entity.Role;

public interface RoleMapper extends BaseMapper<Role> {
	
	@Options(useGeneratedKeys = true, keyProperty = "role_id")
    @InsertProvider(type = SpecialProvider.class, method = "dynamicSQL")
	public int insertList(List<Role> recordList);
	
	public List<Role> selectRoleByUserId(Long userId);
	
	public List<Role> selectRole(Role role);

	//批量删除
	public void deleteBatch(String ids);
}